FROM openjdk:8-jdk-alpine

MAINTAINER liuyanxin@jkstack.com

RUN ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime

RUN mkdir -p /spring-cloud-credit

WORKDIR /spring-cloud-credit

EXPOSE 8083

# arthas 启动需要 --init 模式 进入容器后，会需要unset JAVA_TOOL_OPTIONS
COPY --from=hengyunabc/arthas:latest /opt/arthas /opt/arthas

RUN apk add --no-cache tini

ENTRYPOINT ["/sbin/tini", "--"]

ADD ./build/libs/spring-cloud-credit-1.0-RELEASES.jar ./

CMD java -jar spring-cloud-credit-1.0-RELEASES.jar